package com.nzw.pojo.admin;

import javax.persistence.Column;
import javax.persistence.Table;
import java.io.Serializable;
import java.util.Date;

/**
 * Created by Administrator on 2018\3\17 0017.
 * 管理员实体类
 */

@Table(name = "t_admin")
public class GSAdmin implements Serializable {

    private Long id;                //id
    private String name;            //登录名
    private String password;        //登录密码
    private String nick;            //昵称
    private String head;            //头像
    private Long roleId;            //角色id
    private Boolean state;          //状态:1正常 0为锁定不允许登录
    private Long parentId;          //上级id
    private Long shopId;            //商户id
    private Long companyId;         //企业id
    private int loginNum;           //登录次数
    private Date lastDate;          //最hou登录时间
    private Date loginDate;          //登录时间



    @Column(name = "id")
    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }


    @Column(name = "name")
    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }


    @Column(name = "head")
    public String getHead() {
        return head;
    }

    public void setHead(String head) {
        this.head = head;
    }

    @Column(name = "password")
    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }


    @Column(name = "nick")
    public String getNick() {
        return nick;
    }

    public void setNick(String nick) {
        this.nick = nick;
    }


    @Column(name = "roleId")
    public Long getRoleId() {
        return roleId;
    }

    public void setRoleId(Long roleId) {
        this.roleId = roleId;
    }


    @Column(name = "state")
    public Boolean getState() {
        return state;
    }

    public void setState(Boolean state) {
        this.state = state;
    }


    @Column(name = "parentId")
    public Long getParentId() {
        return parentId;
    }

    public void setParentId(Long parentId) {
        this.parentId = parentId;
    }


    @Column(name = "shopId")
    public Long getShopId() {
        return shopId;
    }

    public void setShopId(Long shopId) {
        this.shopId = shopId;
    }


    @Column(name = "companyId")
    public Long getCompanyId() {
        return companyId;
    }

    public void setCompanyId(Long companyId) {
        this.companyId = companyId;
    }

    @Column(name = "loginNum")
    public int getLoginNum() {
        return loginNum;
    }

    public void setLoginNum(int loginNum) {
        this.loginNum = loginNum;
    }
    @Column(name = "lastDate")
    public Date getLastDate() {
        return lastDate;
    }

    public void setLastDate(Date lastDate) {
        this.lastDate = lastDate;
    }

    @Column(name = "loginDate")
    public Date getLoginDate() {
        return loginDate;
    }

    public void setLoginDate(Date loginDate) {
        this.loginDate = loginDate;
    }

    @Override
    public String toString() {
        return "GSAdmin{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", password='" + password + '\'' +
                ", nick='" + nick + '\'' +
                ", roleId=" + roleId +
                ", state=" + state +
                ", parentId=" + parentId +
                ", shopId=" + shopId +
                ", companyId=" + companyId +
                ", loginNum=" + loginNum +
                ", lastDate=" + lastDate +
                ", loginDate=" + loginDate +
                '}';
    }
}
